#pragma once

#include <QByteArray>
#include <memory>

#include "CharType.h"

class Object
{
public:
    Object(const QByteArray& data, bool builtin = false);

public:
    QByteArray Data();
    void Add(CharTypePtr character);
    void Reset();

    bool IsDigit();
    int  ToInt();

private:
    QByteArray _buffer;
    bool       _builtin;
};

typedef std::tr1::shared_ptr<Object> ObjectPtr;